<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script type="text/javascript" src="../js/vue.js"></script>
</head>
<body>

<div id="app">
    <img src="img/6.jpg" width="200" v-show="age>18&&age<36">
    <hr>
    <!--v-show通过style中disable来控制标签的显示和隐藏   v-if:通过删除和创建标签来控制-->
    <img src="img/9.jpg" width="200" v-if="age>18&&age<36">
    <button @click="run">点击</button>
</div>

<script>
    let app = new Vue({
        el:"#app",
        data:{
            age:18
        },
        methods:{
            run(){
                this.age++
            }
        }
    })
</script>
</body>
</html>